package org.example.design.designmode.decoratorpattern.simple;

public class Test {
    public static void main(String[] args) {
        Battercake battercake;
        battercake = new BaseBattercake();

        battercake = new EggDecorator(battercake);
        battercake = new SausageDecorator(battercake);
        battercake = new MilkDecorator(battercake);
        System.out.println(battercake.getMsg()+ "总价"+battercake.getPrice());


    }
}
